import Vue from 'vue'
import App from './App.vue'
import router from "@/router"
import store from "@/store"
// 导入typenav组件
import TypeNav from "@/components/TypeNav"
// 导入pagination组件
import Pagination from "@/components/Pagination"
// 导入Dialog组件
import Dialog from "@/components/Dialog"
// 导入 mockServer
import '@/mockServer'
// 导入swiper的css样式
import "swiper/css/swiper.min.css"

Vue.config.productionTip = false

// 将TapNav组件注册为全局性组件
Vue.component(TypeNav.name, TypeNav)
// 将Pagination组件注册为全局性组件
Vue.component(Pagination.name,Pagination)
// 将DiaLog组件注册为全局性组件
Vue.component(Dialog.name,Dialog)

new Vue({
  render: h => h(App),
  router,
  // 添加全局事件
  beforeCreate() {
    Vue.prototype.$bus = this
  },
  store,
}).$mount('#app')
